During the operation of a fuel cell, there exists in the anode stream of the anode loop water vapor, nitrogen and residual gases such as argon, for example, in addition to a fuel gas such as hydrogen. The rates of flow of each of these gases in the anode stream can be used to determine the composition of the gases in the anode stream. This information can be used to determine the need to purge the anode loop of the fuel cell, to increase or decrease humidification of the anode loop, and adjust the intake of fuel into a fuel cell stack. Conventional thermal mass flow sensors can be calibrated to measure the flow rates of two gases in a common gas stream. However, for purposes of determining the composition of gases in an anode gas stream of a fuel cell, conventional thermal mass flow sensors are largely insufficient.